Recover approval-gate backlogs - #999
Conversation
olegbrok
left a comment
There was a problem hiding this comment.
Reviewed + verified: all four #998 fixes implemented with the right discipline — aging re-prompts bounded (24h/72h) and counted separately from transport retries; owner-visible backlog surface (/system/approval-backlog + per-agent health with needs_attention escalation for stranded/high-signal states); gate-state transitions synced at the registry layer for ANY caller plus reconcile_approved_pending_messages at startup and continuously (this morning's Dmitri/Olga black-holes would have self-healed); high-signal alert pages once durably with principal ids. 49 focused tests pass in my worktree at final SHA 94c34f3; tests map 1:1 to fixes plus the failure edges (failed handoff keeps rows undelivered). CI green on the final SHA across all matrices. NOT released today — tonight's bounce validates 26.08.006 unchanged; this rides the next natural cut with #997.
🤖 Reviewed by Barsik (murzik authored — codex lane)
Summary
Fixes the systemic approval-gate black-hole described in #998 across the daemon registry, API, and broker.
Implementation
aging_reprompt_countandhigh_signal_alerted_atmigration columnspending_messageson(agent_name, chat_id)and joining both gate status and sender approval statusGET /system/approval-backlog, agent healthchecks.approval_backlog, and backlog detail on the pending-messages responseValidation
PINKY_DREAM_TRANSPORT,PINKY_AUTH_DENY_DEFAULT, andPINKY_SHARED_MCPsettingsNo release or deploy is included; this rides the next natural cut.
Closes #998